package com.zezheng.qian.project.anxinsign.dto;

import com.alibaba.fastjson.annotation.JSONField;
import com.fasterxml.jackson.annotation.JsonIgnore;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

@Data
public class Head {
    @ApiModelProperty(value = "交易时间：yyyyMMddHHmmss")
    private String txTime;

    @ApiModelProperty(value = "返回代码")
    private String retCode = "";

    @ApiModelProperty(value = "请求的地区")
    private String locale = "";

    @ApiModelProperty(value = "返回信息")
    private String retMessage = "";

    @ApiModelProperty(value = "返回代码（错误码）")
    private String errorCode;

    @ApiModelProperty(value = "返回信息（错误信息）")
    private String errorMessage;

    @JsonIgnore
    @JSONField(serialize = false, deserialize = false)
    public boolean isSuccess() {
        return "60000000".equals(this.retCode);
    }
}
